%ifdef CONFIG
{
  "RegData": {
    "MM0": "0x0",
    "MM1": "0x0",
    "MM2": "0x3fff000100000001",
    "MM3": "0x0000000200000004"
  },
  "HostFeatures": ["3DNOW"]
}
%endif

movq mm0, [rel data5]
movq mm1, [rel data6]
movq mm2, [rel data7]
movq mm3, [rel data8]

; nasm doesn't support emitting this instruction
; pmulhrw mm0, [rel data1]
db 0x0f, 0x0f, 0x05, 0x1c, 0x00, 0x00, 0x00, 0xB7
; pmulhrw mm1, [rel data2]
db 0x0f, 0x0f, 0x0d, 0x1c, 0x00, 0x00, 0x00, 0xB7
; pmulhrw mm2, [rel data3]
db 0x0f, 0x0f, 0x15, 0x1c, 0x00, 0x00, 0x00, 0xB7
; pmulhrw mm3, [rel data4]
db 0x0f, 0x0f, 0x1d, 0x1c, 0x00, 0x00, 0x00, 0xB7

hlt

align 8
data1:
  dw 0x0
  dw 0x0
  dw 0x0
  dw 0x0

data2:
  dw 0x1
  dw 0x1
  dw 0x1
  dw 0x1

data3:
  dw 0x2
  dw 0x2
  dw 0x2
  dw 0x7FFF

data4:
dw 0x10
dw 0x4
dw 0x8
dw 0x8

data5:
  dw 0x0
  dw 0x0
  dw 0x0
  dw 0x0

data6:
  dw 0x1
  dw 0x1
  dw 0x1
  dw 0x1

data7:
dw 0x7FFF
dw 0x2
dw 0x7FFF
dw 0x7FFF

data8:
dw 0x3E80
dw 0x4
dw 0x3E80
dw 0x4
